package raceReservationServer;

import java.rmi.RemoteException;
import java.sql.SQLException;
import java.util.List;

import raceReservationServer.loginGateway.RunnerDO;
import raceReservationServer.loginGateway.RunnerRMIDTO;
import raceReservationServer.loginGateway.ValidationException;
import util.observer.rmi.IRemoteObservable;

/**
 * REMOTE INTERFACE TO BE IMPLEMENTED BY THE REMOTE SERVER WHICH IS THE REMOTE
 * OBSERVABLE FACADE
 * 
 * TO BE COMPLETED BY THE STUDENTS
 */
public interface IReservationRaceServer extends IRemoteObservable
{
	
	public abstract void addRemoteObserver(util.observer.rmi.IRemoteObserver arg0) throws java.rmi.RemoteException;
	public abstract void deleteRemoteObserver(util.observer.rmi.IRemoteObserver arg0) throws java.rmi.RemoteException;
	
	public RunnerRMIDTO login(String user, String pass)throws ValidationException, RemoteException;
	public List<RaceRMIDTO> getRaces() throws RemoteException;
	public void reservePlace(String runnerName, String raceServer, String raceName)throws RemoteException, SQLException;
}
